package bean;


public class Repertoires {
	private Integer id_repertoire;
	private String adresse;
	private String libelle;
	private String type;
	private Classe classe = new Classe();
	private Matiere matiere = new Matiere();
	private Apprenti apprenti = new Apprenti();
	public static final String TYPE_PLANNING_HEBDO = "planning_hebdo";
	public static final String TYPE_PLANNING_ANNUEL = "planning_annuel";
	public static final String TYPE_PHOTO = "photo";
	public static final String TYPE_PROGRESSION_PEDA = "progression_peda";
	public static final String TYPE_DOCUMENT = "document";
	public static final String CHEMIN_PLANNING = "PLANNINGS";
	public static final String CHEMIN_PHOTO = "PHOTOS";
	public static final String CHEMIN_PROGRESSION_PEDA = "PROGRESSION PEDAGOGIQUE";
	public static final String CHEMIN_DOCUMENT = "DOCUMENTS";
	public Repertoires(){

	}
	
	public Repertoires(Integer id_repertoire, String adresse, String libelle,
			String type, Classe classe, Matiere matiere, Apprenti apprenti) {
		super();
		this.id_repertoire = id_repertoire;
		this.adresse = adresse;
		this.libelle = libelle;
		this.type = type;
		this.classe = classe;
		this.matiere = matiere;
		this.apprenti = apprenti;
	}
	
	public Integer getId_repertoire() {
		return id_repertoire;
	}
	public void setId_repertoire(Integer id_repertoire) {
		this.id_repertoire = id_repertoire;
	}
	public String getAdresse() {
		return adresse;
	}
	public void setAdresse(String adresse) {
		this.adresse = adresse;
	}
	public String getLibelle() {
		return libelle;
	}
	public void setLibelle(String libelle) {
		this.libelle = libelle;
	}
	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	public Classe getClasse() {
		return classe;
	}
	public void setClasse(Classe classe) {
		this.classe = classe;
	}
	public Matiere getMatiere() {
		return matiere;
	}
	public void setMatiere(Matiere matiere) {
		this.matiere = matiere;
	}
	public Apprenti getApprenti() {
		return apprenti;
	}
	public void setApprenti(Apprenti apprenti) {
		this.apprenti = apprenti;
	}
		
	public String getNameFile(){
		String nameFile = "";
		String[] TNameFile = this.adresse.split("/");
		nameFile = TNameFile[TNameFile.length - 1];
		return nameFile;
	}
	
}
